package com.egov.config.annotation.dic;

import com.egov.business.common.service.CommonService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

import javax.annotation.PostConstruct;
import java.util.Map;

/**
 * Created with IntelliJ IDEA.
 * Description: 字典翻译数据获取工具类
 *
 * @Author: denggang
 * @Date: 2018-09-11 9:25
 **/
@Component
public class DicUtils {

    private static DicUtils dicUtils;

    @Autowired
    private CommonService commonService;

    @PostConstruct
    public void init() {
        dicUtils = this;
        dicUtils.commonService = this.commonService;
    }

    public static DicItem getDic(Map<String,Object> map) {
        return dicUtils.commonService.dicTranslate(map);
    }

}
